<style rel="stylesheet/scss" lang="scss" scoped>
.container{
    display: flex;
    justify-content: center;
    .dragWrapper {
        width: 1001px;
        height: 701px;
        overflow: hidden;
        position: relative;
    }
}
</style>
<template>
    <div class="container">

        <div class="dragWrapper avue-grid">

            <div style="position:relative;height:400px;" @mousedown="handleMouseDown">
                <avue-draggable ref="draggable" :width="obj.width" :height="obj.height" :left="obj.left" :top="obj.top">
                    
                    <img :src="BgImg" alt="">

                </avue-draggable>
            </div>

        </div>

    </div>
</template>

<script>
import BgImg from '@/assets/images/login_bg_01.jpg'
export default {
    data() {
        return {
            BgImg,
            obj: {
                width: 100,
                height: 100,
                left: 100,
                top: 100
            }
        }
    },
    methods: {
        handleMouseDown() {
            //调用内部方法取消选中，false取消，true激活
            this.$refs.draggable.setActive(false);
        }
    }
};
</script>

<style scoped>
</style>